<?php
use  Anker1992\BasicLib\HttpRequestClient;

require "./vendor/autoload.php";

$curl = new HttpRequestClient();
$getParam = array(
    'name' => 'anker',
    'age' => 23
);
$headers = array(
    'auth-sign' => '1234567890abcdefghijklmnopqrstuvwxyz'
);
$res = $curl->get("http://coolaf.com/tool/params", $getParam, $headers);
var_dump($res);
echo "<br/>";
echo "<br/>";

$postData = array(
    'post_name' => 'douwei',
    'post_age' => 15
);
$postRes = $curl->post("http://coolaf.com/tool/params", $postData, $getParam, $headers);
var_dump($postRes);